# _*_ coding: UTF-8 _*_
# @Time     : 2021/10/21 14:59
# @Author   : yangshuaishuai
# @Site     : http://www.hzdledu.cn/
# @File     : c5s1_if语句.py
# @Software : PyCharm

# 选择结构
# 根据条件，选择程序执行路径
# if语句:1.基本if语句 2.if-else语句 3.if-slif-else语句 4.if语句嵌套

# money = 5
# if money >= 5:
#     print('吃豆浆和包子')
# print('去上课')
#
# age = int(input('请输入年龄'))
# if age > 25:
#     print('请站右边')
# else:
#     print('请站左边')
# # if如果，else否则
# num = int(input('请输入一个数字'))
# if num % 2 ==0:
#     print('偶数')
# else:
#     print('奇数')
# #if-elif-else语句
# score=60
# if score>=90:
#     print('优秀')
# elif score >=80:
#     print('良好')
# elif score>=60:
#     print('及格')
# else:
#     print('不合格')
#

# 根据输入的月份判断春夏秋冬四个季节
sea = int(input('请输入月份:'))
if 3 <= sea <= 5:
    print('春')
elif 5 < sea <= 8:
    print('夏')
elif 8 < sea <= 11:
    print('秋')
elif 1 < sea > 13:
    print('请输入正确月份')
elif  sea < 1:
    print('请输入正确月份')
else:
    print('冬')
#再如果
sea = int(input('请输入月份:'))
if sea in(3,4,5):
    print('春')
elif sea in(6,7,8):
    print('夏')
elif sea in(9,10,11):
    print('秋')
elif sea in(12,1,2):
    print('冬')
else:
    print('请输入正确月份')
 # 老婆让程序员去菜市场买菜，说：“去买两个番茄。如果有新鲜西瓜，买一个，如果西瓜不新鲜，买个哈密瓜”
hasMelon = True
if hasMelon:
    isFresh = False
    if isFresh:
        print('买个西瓜')
    else:
        print('买个哈密瓜')
    print('买两个番茄')
